//
// Created by wze-zero on 2024/8/23 023.
//
#include <iostream>
#include <iomanip>

using namespace std;

int main() {
    double f, c;
    cin >> f;
    c = (double) 5 / 9 * (f - 32);
    cout << fixed << setprecision(3) << c << endl;
    return 0;
}